package GUI;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import java.awt.Dimension;
import java.util.ArrayList;

import javax.swing.JFrame;
import Entity.ActivityReport;
import Entity.Parformance_report;
import GUI.ActivityReportOutputGui;
import Control.ReportControl;
import java.awt.Color;

public class rr extends JFrame{
private Parformance_report p_r;
private ArrayList<Integer> arr;
private ActivityReportOutputGui ARO;	
private ActivityReport ARE;
private ReportControl ell;
private ParformanceReportGui PRG;
public  rr () {
	p_r = new Parformance_report();
	 arr = new ArrayList<Integer>();
	setMinimumSize(new Dimension(700, 400));
	setMaximumSize(new Dimension(700, 400));
	//getContentPane().setLayout(null);
	ARO = new ActivityReportOutputGui();
	PRG = new ParformanceReportGui();
	PRG.setToolTipText("gjhghj");
	PRG.setForeground(Color.DARK_GRAY);
	
	ARE= new ActivityReport();
	
	ell = new ReportControl();
}
public void fun(){
	ARE.setActiveReqDuration(12);
	ARE.setRejectReqDuration(12);
	ARE.setClosedReqDuration(12);
	ARE.setFrozenReqDuration(12);
	ell.fillParformanceReport(p_r);
//ell.fillActivityreport(ARR);
//System.out.println("hhhhhhhhhhhhhhhhhhhhhh ");
	arr.add(0, 10);
	arr.add(1, 10);
	arr.add(2, 10);
	arr.add(3, 10);
ARO.getTable_1().setValueAt("elad", 2, 2);
ARO.getTable_1().setValueAt("nofar", 3, 2);


ARO.getButton().addActionListener(new ActionListener() {
	
	@Override
	public void actionPerformed(ActionEvent e) {
		add(PRG);
		setContentPane(PRG);
	    setVisible(true);	
			
	}
});


     add(ARO);
   setContentPane(ARO);
    setVisible(true);
}

//public void  Action_listener_operations(){
	//active_rep_gui = active_rep. getActive_rep();
	

		
	public static void main(String[] args) {
		rr eladf = new rr();
         eladf.fun();
	}

}
